package ThirdCommunication;

import java.io.Serializable;

//对象继承Serializable接口，实现序列化，可以通过I/O流传递
public class User implements Serializable {
    private String id;
    private String pwd;
    private Boolean alive;//是否在线
    public User() {
    }
    public User(String id, String pwd){
        this.id = id;
        this.pwd = pwd;
    }

    public Boolean getAlive() {
        return alive;
    }

    public void setAlive(Boolean alive) {
        this.alive = alive;
    }

    public User(String id, String pwd, Boolean alive){
        this.id = id;
        this.pwd = pwd;
        this.alive = alive;
    }

    public void setId(String id) {
        this.id = id;
    }

    public void setPwd(String pwd) {
        this.pwd = pwd;
    }

    public String getId() {
        return id;
    }

    public String getPwd() {
        return pwd;
    }

}
